<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%>
<%@ taglib prefix="s" uri="/struts-tags" %>
<%@ page import="java.util.*, cs5226.util.StringUtil" %>
<jsp:useBean id="baseline" class="cs5226.model.BaselineBean" scope="page"/>
<%
	Map aMap = null;
	baseline=null;
	if(null!=request.getAttribute("baselineMap"))
		aMap = (Map) request.getAttribute("baselineMap");
%>

<h2>Baseline Comparison Result</h2>
	
<br/><br/><br/>

<style>

table
{
border-collapse:collapse;
}
table,th, td
{
border: 1px solid gray;
}
</style>


		<%
			if (request.getAttribute("msg") != null) {
		%>
		<center><font color="red"><%=request.getAttribute("msg")%></font></center>
		<%
			}
		%>
<table>
	<%if(aMap!=null && aMap.size()>0){ 
		Iterator it = aMap.keySet().iterator();
		String key = "";
		while(it.hasNext()){
			key = it.next().toString();
			if(null!=aMap.get(key)){%>
				<tr><td><b><%=key%></b></td>
			<%
				List aList = (List) aMap.get(key);
				for(Object str:aList){%>
					<td><%=(String)str%></td>
				<%}%>
				</tr>
			<%}
		}%>
	<%}else{%>
		<tr><td>No Baseline Available!</td></tr>
	<%}%>
</table>

<script>
	$(function() {		
		$('.button').button();
	});
</script>